//
// Created by 高森森 on 2022/9/26.
//

#ifndef LEETCODE_SOLUTION_7_H
#define LEETCODE_SOLUTION_7_H
#include<bits/stdc++.h>
using namespace std;

class solution_7 {
public:
    vector<int> findDisappearedNumbers(vector<int>& nums) {
        set<int>p;
        int n=nums.size();
        for(int i=0;i<n;i++){
            p.insert(nums[i]);
        }
        vector<int>res;
        for(int i=1;i<=n;i++){
            if(p.count(i)==0){
                res.push_back(i);
            }
        }
        return res;
    }
};


#endif //LEETCODE_SOLUTION_7_H
